Display Mode QT Atom Container
The
QTVideoOutputGetDisplayModeList
function returns a list of the display modes supported by a video display component. This list is contained in the QT atom container described in this section. For more information about QT atom containers, see
"QuickTime Atoms" (page 47)
.
At the root of the QT atom container returned by the
QTVideoOutputGetDisplayModeList
function are one or more atoms of type
kQTVODisplayModeItem
, each containing a definition of a display mode. Your software can traverse the display mode atoms by calling the
QTFindChildByIndex
function.
Within each
kQTVODisplayModeItem
atom are the following atoms:
-
The atom of type
kQTVODimensions
with ID 1 contains two 32-bit integers. The first specifies the width, in pixels, of the display. The second specifies the height, in pixels, of the display.
-
The atom of type
kQTVOResolution
with ID 1 contains two 32-bit fixed-point values. The first specifies the horizontal resolution of the display, in pixels per inch. The second specifies the vertical resolution of the display, in pixels per inch.
By storing resolutions rather than an aspect ratio, QuickTime makes it easy for your software to compare values with values in QuickTime
ImageDescription
records. Your software can calculate the aspect ratio for the display mode by dividing the value for the horizontal resolution by the value for the vertical resolution.
-
The atom of type
kQTVORefreshRate
with ID 1 contains a single 32-bit fixed-point value. This value specifies the refresh rate of the display in Hertz.
-
The atom of type
kQTVOPixelType
with ID 1 contains a single 32-bit OSType value. This value specifies the type of pixel that is used by the display format:
-
Values of 1, 2, 4, 8, 16, 24 and 32 specify standard Mac OS RGB pixel formats with corresponding bit depths.
-
Values of 33, 34, 36 and 40 specify standard Mac OS gray-scale pixel formats with depths of 1, 2, 4, and 8 bits per pixel.
-
Other pixel formats are specified by four-character codes. There are currently codes for RGB pixel formats defined for Microsoft Windows and for several YUV formats. For information about pixel formats defined for Microsoft Windows, see
Introduction to QuickTime 3 for Windows Programmers.
-
The atom of type
kQTVOName
with ID 1 contains a string that describes the display mode. Your software can use this string when presenting a list of available display modes to the user. The string does not include a leading length byte or a trailing null. Your software can determine the length of the string by getting the size of the atom that contains it.
-
Atoms of type
kQTVODecompressors
specify any special decompressors that are required for the video output device. If a video output device cannot directly display 32-bit RGB data or data in one of the other supported QuickTime pixel formats, a special decompressor is required to convert images to data that the video output device can display.
Because
kQTVODecompressors
atoms are not required to have consecutive IDs, your software must use the
QTFindChildByIndex
function to iterate through the decompressors.
Within each
kQTVODecompressors
atom are one or more atoms:
-
The atom of type
kQTVODecompressorType
with ID 1 contains an
OSType
value that specifies the type of compressed data that the decompressor can decompress. For example, a
kQTVODecompressorType
atom that contains
kMotionJPEGACodecType
can decompress Motion JPEG Format A data.
-
An atom of type
kQTVODecompressorComponent
with ID 1 is optional. If present, it contains a
DecompressorComponent
value that specifies a decompressor component that your software can use to decompress the data specified by the corresponding
kQTVODecompressorType
atom.
-
An atom of type
kQTVODecompressorContinuous
with ID 1 is optional. If present, it contains a Boolean value that specifies whether the resulting video display will be continuous. If the value is
true
, data will be displayed without any visual gaps between successive images. If the value is
false
, data will be displayed, but there may be a visual gap (such as a black screen) between the display of images. If there is no
kQTVODecompressorContinuous
atom, your software should not make any assumptions about the performance of the decompressor.
© 1999 Apple Computer, Inc.| Previous | Chapter Contents | Chapter Top | Next |